Hi all, I've managed to build my DXL GUI and the functionality quite well, but I've hit a wall here. What I'm trying to achieve is a tab, which based on the choice from a drop-down list, has labels that are updated with values from doors. The data is presented in a column of around 25 rows with about 6 columns. I've initially set this out, and then tried to move this into a callback function, but the callback does not actually update the labels. I guess because I'm trying to create new ones, but it doesn't overwrite the originals (I think the values are being pulled out, but the GUI either isn't updated, or it is, but not in a place I can see).
As there are so many of them, I can not simply do a set command with the label, as that would end up with 300 sets, which is a little too much. Is there a way of creating an array of DBE labels, which I can then loop through and do a set command on in a callback? Or is there a way of destroying the original tab and then recreating it in a new tab or something?
As an aside, the Doors application I'm running is on a Citrix server, and so I can not locally talk to it with a C# program, which would make all the GUI design work easier for me. Is there a way to have a program that accesses the Doors server remotely? I've only ever done it with a local copy of Doors installed.
Thanks.
DataHoarder - Wed Apr 18 11:04:48 EDT 2018 |
Re: Update Labels on a Tab with Callback Not sure what exactly you are doing / trying to do. So far from my side: - You can modify the entries of comboboxes, lists, listviews dynamically. The first intialization is via an array that you pass to the DBE constructor. Afterwards there are functions to insert and delete items (see examples on the forum). - You cannot recreate GUI elements once they are created - or add others to the GUI. Once you "show" or "realize" or "block" the GUI you cannot modify the GUI structure anymore - you can hide and show elements though. Therefore in dynamic GUIs one way to achieve what you describe is to create all GUI elements, but hide all of them and show only one of them. You need to use constrained placement to put all variants at the same place. But usually this approach is too cumbersome and only usable for very few use cases. Regarding c# lets stay at the other post. Regards. Mathias |
Re: Update Labels on a Tab with Callback So, I have a tab which when opened will have a drop down choice box with many programs in.
Underneath I have a table, which I have created with about 300 labels in total (about 25 rows, 6 columns). Initially I set the header row and the left hand column to values which will not change. The rest of the labels I just set to dashes.
When a user selects a choice from the dropdown and then press an update button, I want the labels that have dashes in them, to update with the numbers corresponding to the choice.
What would be great is if I could create an array of DBEs and then call the "set" function, so i can update the label from dashes to the correct number.
So, is it OK to create an array like this:
In the first for loop obviously i would set their locations too. Is that something that DXL will support?
|
Re: Update Labels on a Tab with Callback DataHoarder - Mon Apr 23 06:27:11 EDT 2018 So, I have a tab which when opened will have a drop down choice box with many programs in.
Underneath I have a table, which I have created with about 300 labels in total (about 25 rows, 6 columns). Initially I set the header row and the left hand column to values which will not change. The rest of the labels I just set to dashes.
When a user selects a choice from the dropdown and then press an update button, I want the labels that have dashes in them, to update with the numbers corresponding to the choice.
What would be great is if I could create an array of DBEs and then call the "set" function, so i can update the label from dashes to the correct number.
So, is it OK to create an array like this:
In the first for loop obviously i would set their locations too. Is that something that DXL will support?
While that would be technically possible I suggest you take a look at "SkipLists" instead of using a array.
Also it sounds a lot like you are basically recreating the "ListView" Dialogbox Element, but with a bunch of labels... which might not be the most elegant way of solving this. I suggest you take a look at the two mentioned keywords in the DXL Reference Manual, maybe those already solve your problem. |